import axios from "axios";
import nProgress from "nprogress";

const ajaxRequest = axios.create({
    timeout:5000
})

ajaxRequest.interceptors.request.use((config)=>{
    nProgress.start()
    return config
})

ajaxRequest.interceptors.response.use((res)=>{
    nProgress.done()
    return res.data
},()=>{})

export default ajaxRequest

